package com.kaigejava.DecoratorModelzhuangshizhe.myio;

import java.io.BufferedInputStream;
import java.io.FileInputStream;
import java.io.IOException;
import java.io.InputStream;

/**
 * Created by kaigejava on 2019/8/14.
 * 测试类
 */
public class UpperCaseInputStreamMian {
    public static void main(String[] args) {
        int c;
        try {
            //调用我们自己写的转换大写类
            InputStream in = new UpperCaseInputStream(new BufferedInputStream(
                    new FileInputStream("d:\\myioinput.txt")));
            while((c=in.read())>=0)
            {
                System.out.print((char)c);
            }
        } catch (IOException e) {
            e.printStackTrace();
        }
    }
}